package com.zqh.myfmmall.clients;

import com.zqh.myfmmall.fallback.MqMessageClientFallback;
import com.zqh.myfmmall.result.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * @Description :
 * @Author :kono淇杭哒、
 * @Create 2022-03-01 23:14
 */
@FeignClient(value = "message-mq",fallbackFactory = MqMessageClientFallback.class)
public interface MqMessageClient{
    @PostMapping("messageMq/delayedMessage")
    Result delayedMessage(@RequestParam("message") String message);

    @PostMapping("messageMq/delayedMessage")
    Result delayedMessage(@RequestParam("message") String message, @RequestParam(value = "ttl") Integer ttl);
}
